//Name:
//Purpose:
//Author: wjy
//Date: 2022-01-25 10:27:37
//From:

#include <stdio.h>
#include <stdlib.h>

int main(void)
{
    int m, n, temp;
    printf("Enter two integers: ");
    scanf("%d %d", &m, &n);
    while (1)
    {
        if (n == 0)
        {
            break;
        }
        else
        {
            temp = m % n;
            m = n;
            n = temp;
        }
    }
    printf("GCD: %d\n", m);
    system("pause");
    return 0;
}